﻿@using Kugar.AdminLte.Core.Test.Models.Home
@using Kugar.Core.ExtMethod
@using Kugar.UI.Web.AdminLTE.Helpers

@model Model_List

@{
    WebUI.Title = "测试2";

    WebUI.CurrentMenuKey = "InnerTest2";

    WebUI.Breadcrumbs = new[]
    {
        new BreadcrumbItem("InnerTest1", "/IFrameTest/InnerTest1"),
        new BreadcrumbItem("InnerTest2", "/IFrameTest/InnerTest2"),
    };
}

@using (var dl = WebUI.Control.DataList<TableTest>().Render())
{
    using (var db = dl.DataBlock.Render())
    {
        using (var tbl = db.Table.Data(Model.Data).Render())
        {
            @tbl.Columns.AddIndex()

            @tbl.Columns.AddLabel().ColumnTitle("UserName1").Value(x => x.UserName1)

            @tbl.Columns.AddLabel().ColumnTitle("UserName2").Value(x => x.UserName2)

            @tbl.Columns.AddLabel().ColumnTitle("UserName3").Value(x => x.UserName3.ToStringEx("yyyy-MM-dd"))

            @tbl.Columns.AddLabel().ColumnTitle("UserName4").Value(x => x.UserName4.ToString())

            @tbl.Columns.AddLabel().ColumnTitle("UserName5").Value(x => x.UserName5)

            @tbl.Columns.AddLabel().ColumnTitle("UserName6").Value(x => x.UserName6)

            @tbl.Columns.AddLabel().ColumnTitle("UserName7").Value(x => x.UserName7)

            @tbl.Columns.AddLabel().ColumnTitle("UserName8").Value(x => x.UserName8)
        }
    }
}